计算机器怎么制造
㈠ 如何制作简单的计算器
(1)先画个页面,把每个数字
运算符号放进去;
(2)然后每个数字
符号绑定一个事内件,这个事件获取数字或容者符号的值,放进一个Input框;
(3)点击计算,把Input框的字符串
表达式计算
,eval("1*2");
(4)还有计算前要对表达式进行校验,不规则的表达式不能计算。
㈡ 怎样制作一台计算器(不是计算机,不是用电脑软件制作)
不能
只能用软件来做你所看的的计算机不管大小其实都是调用的一种程序芯片里边的程序
这种程序是加载好的
㈢ 你知道计算器是如何做出来的吗
你去找本经济学书,上面讲资金的时间价值的章节就有计算贷款还款的几个公式
然后你用excel 就可版以把公式和变量权写好 然后计算 这个是最简单的
复杂点就编程吧,至于编程语言,那就太多了,几乎都能做出这个东西
不过这是一个知识体系的问题了
如果我上面说的,你一句都不懂,那就去网上下个现成的吧
㈣ 计算器的屏幕是怎么制造的
是液晶屏幕
上下2块玻璃,中间是液晶,玻璃上有透明电路,加电压液晶分子回偏转,光线不能反射回来,就变答成黑色的
http://ke..com/link?url=ZpL3__W30c5ILyXnJXat4myc31oC_QJRVqfKk4RNCzMdgvMKMIK
㈤ 电脑是怎么做出来的
电脑的主板、CPU等等部件都是独立生产的,然后集成在一起。CPU是超大规模集成电路,在一块九平方厘米或者十六平方厘米左右的集成板上集成数以亿计的晶体管,主要是CMOS、PMOS等。最初计算机有几个部件:运算器、控制器、存储器、输入输出设备。运算器就是现在的电脑的CPU,但是现在的CPU已经比较复杂,不再是单纯的计算器,因为都集成了缓存和控制器,集成了部分存储器的性质。其中典型的一级代码缓存,二级数据缓存和最新的三级数据缓存。控制器用于发出和接受指令——控制计算和数据的输入输出。存储器就是ROM和RAM,ROM是只读存储器,存储的数据是运算器工作的流程和模式,不可以更改,RAM是可擦除存储设备,可以写入程序还可以更改或者清除。输入输出设备包括最初的输入输出总线、接口和现在的电脑上的鼠标、键盘、网线、显示器、摄像头、话筒、打印机,指纹头像识别识别以及一些高端设备上的先进的语音指令系统、视频指令系统等等。
现在的电脑,主板主要集成了总线以及总线接口和后来加的输入输出设备辅助设备——显卡。主要存储设备由于操作系统的出现需要插在主板内存接口上——内存插槽。系统所占的部分相当于ROM,一旦变成RAM就是中了病毒木马,其余部分相当于RAM。很多手机厂商根本分不清ROM和RAM,在中关村网站上这种错误太多了。只有RAM部分才可以装软件,ROM部分是只读的,一般不可以更改,除非刷机重装系甚至崩溃,危害极大的病毒木马就是这个原理用程序编写的。对于一台电脑,以上是硬件设备,还有软件设备,一般存储在ROM-部分内存中,主板的BIOS相当于主板的ROM+RAM对主板支持其他设备运行进行控制和支持。所以现在的电脑已经不是单一计算机系统,而是多个系统的集成。软件部分本人了解的不多,组成更复杂,本质都是汇编以及C系语言程序,当然手机和小型系统一般都用JAVA编程
㈥ 怎么做一个JAVA计算器
classCalcBtnextendsJButton{
=1L;
Fontfont=newFont("仿宋",1,22);
publicCalcBtn(Stringtext,Colorcolor){
(text);
setForeground(color);
setFont(font);
setMargin(newInsets(0,0,0,0));
setFocusable(false);
}
}
@SuppressWarnings("serial")
{
publicstaticvoidmain(String[]args){
try{
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
}catch(Exceptionex){
ex.printStackTrace();
}
newCalcFrame().setVisible(true);
}
privateCalcBtnbtn_1=newCalcBtn("1",Color.BLUE);
privateCalcBtnbtn_2=newCalcBtn("2",Color.BLUE);
privateCalcBtnbtn_3=newCalcBtn("3",Color.BLUE);
privateCalcBtnbtn_4=newCalcBtn("4",Color.BLUE);
privateCalcBtnbtn_5=newCalcBtn("5",Color.BLUE);
privateCalcBtnbtn_6=newCalcBtn("6",Color.BLUE);
privateCalcBtnbtn_7=newCalcBtn("7",Color.BLUE);
privateCalcBtnbtn_8=newCalcBtn("8",Color.BLUE);
privateCalcBtnbtn_9=newCalcBtn("9",Color.BLUE);
privateCalcBtnbtn_0=newCalcBtn("0",Color.BLUE);
privateCalcBtnbtn_back=newCalcBtn("←",Color.red);
privateCalcBtnbtn_c=newCalcBtn("C",Color.red);
privateCalcBtnbtn_ce=newCalcBtn("CE",Color.red);
privateCalcBtnbtn_sub=newCalcBtn("-",Color.red);
privateCalcBtnbtn_multi=newCalcBtn("*",Color.red);
privateCalcBtnbtn_div=newCalcBtn("/",Color.red);
privateCalcBtnbtn_add=newCalcBtn("+",Color.red);
privateCalcBtnbtn_sqrt=newCalcBtn("sqrt",Color.BLUE);
privateCalcBtnbtn_mod=newCalcBtn("%",Color.BLUE);
privateCalcBtnbtn_x=newCalcBtn("1/x",Color.BLUE);
privateCalcBtnbtn_res=newCalcBtn("=",Color.red);
privateCalcBtnbtn_point=newCalcBtn(".",Color.red);
privateCalcBtnbtn_flag=newCalcBtn("+/-",Color.BLUE);
privateJButtonbtn_mem=newJButton("");
privateCalcBtnbtn_m=newCalcBtn("M+",Color.BLUE);
privateCalcBtnbtn_mc=newCalcBtn("MC",Color.BLUE);
privateCalcBtnbtn_mr=newCalcBtn("MR",Color.BLUE);
privateCalcBtnbtn_ms=newCalcBtn("MS",Color.BLUE);
JPanelpan_jtf=newJPanel();
JPanelpan_back=newJPanel();
JPanelpan_mem=newJPanel();
JPanelpan_num=newJPanel();
JTextFieldjtf_res=newJTextField();
//
privateJMenuBarmenuBar=newJMenuBar();
privateJMenumenu_edit=newJMenu("编辑(E)");
privateJMenumenu_view=newJMenu("查看(V)");
privateJMenumenu_help=newJMenu("帮助(H)");
privateJMenuItemeditMenu_=newJMenuItem("复制(C)");
privateJMenuItemeditMenu_paste=newJMenuItem("粘贴(P)");
_standard=newJCheckBoxMenuItem(
"标准型(T)");
_science=newJCheckBoxMenuItem("科学型(S)");
_grouping=newJCheckBoxMenuItem(
"数字分组(I)");
privateJMenuItemhelpmenu_help=newJMenuItem("帮助主题(H)");
privateJMenuItemhelpmenu_about=newJMenuItem("关于计算器(A)");
Stringsave1,save2;
BigDecimalop1,op2;
booleanisBigDecimal=false;
intpreOp,currentOp=0;
StringBufferstr=newStringBuffer();
publicCalcFrame(){
this.setTitle("於☆弦");
this.setResizable(false);
setSize(444,390);
setLocationRelativeTo(null);
setDefaultCloseOperation(EXIT_ON_CLOSE);
setJMenuBar(menuBar);
setLayout(null);
init_pan_jtf();
init_menuBar();
init_pan_back();
init_pan_mem();
init_pan_num();
getContentPane().add(pan_jtf);
getContentPane().add(pan_back);
getContentPane().add(pan_mem);
getContentPane().add(pan_num);
}
privatevoidinit_menuBar(){
menuBar.add(menu_edit);
menuBar.add(menu_view);
menuBar.add(menu_help);
menu_edit.add(editMenu_);
menu_edit.add(editMenu_paste);
menu_view.add(viewmenu_standard);
menu_view.add(viewmenu_science);
menu_view.addSeparator();
menu_view.add(viewmenu_grouping);
menu_help.add(helpmenu_help);
menu_help.addSeparator();
menu_help.add(helpmenu_about);
menu_edit.setMnemonic('E');
menu_view.setMnemonic('V');
menu_help.setMnemonic('H');
editMenu_.setMnemonic('C');
editMenu_.setAccelerator(KeyStroke.getKeyStroke('C',
InputEvent.CTRL_MASK));
editMenu_paste.setMnemonic('P');
editMenu_paste.setAccelerator(KeyStroke.getKeyStroke('V',
InputEvent.CTRL_MASK));
viewmenu_standard.setMnemonic('T');
viewmenu_science.setMnemonic('S');
viewmenu_grouping.setMnemonic('I');
helpmenu_help.setMnemonic('H');
helpmenu_about.setMnemonic('A');
}
publicvoidinit_pan_back(){
pan_back.setSize(340,40);
pan_back.setLocation(85,60);
pan_back.setLayout(newGridLayout(1,3,5,0));
pan_back.add(btn_back);
pan_back.add(btn_ce);
pan_back.add(btn_c);
btn_back.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEvente){
if(!jtf_res.getText().trim().equals("0.")){
if(str.length()!=1&&str.length()!=0){
jtf_res.setText(str.delete(str.length()-1,
str.length()).toString());
}else{
jtf_res.setText("0.");
str.setLength(0);
}
}
op2=newBigDecimal(jtf_res.getText().trim());
}
});
btn_c.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEvente){
jtf_res.setText("0.");
op1=op2=newBigDecimal(0);
str.replace(0,str.length(),"");
preOp=currentOp=0;
}
});
btn_ce.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEvente){
jtf_res.setText("0.");
}
});
}
publicvoidinit_pan_jtf(){
jtf_res.setHorizontalAlignment(JTextField.RIGHT);
jtf_res.setFont(newFont("仿宋",0,20));
jtf_res.setText("0.");
jtf_res.setEditable(false);
//jtf_res.setFocusable(false);
pan_jtf.setSize(420,40);
pan_jtf.setLocation(10,5);
pan_jtf.setLayout(newBorderLayout());
pan_jtf.add(jtf_res);
}
publicvoidinit_pan_mem(){
pan_mem.setSize(60,270);
pan_mem.setLocation(10,60);
pan_mem.setLayout(newGridLayout(5,1,0,5));
pan_mem.add(btn_mem);
btn_mem.setEnabled(false);
pan_mem.add(btn_mc);
pan_mem.add(btn_mr);
pan_mem.add(btn_ms);
pan_mem.add(btn_m);
}
publicvoidinit_pan_num(){
pan_num.setSize(340,220);
pan_num.setLocation(85,110);
pan_num.setLayout(newGridLayout(4,5,5,5));
pan_num.add(btn_7);
pan_num.add(btn_8);
pan_num.add(btn_9);
pan_num.add(btn_div);
pan_num.add(btn_sqrt);
pan_num.add(btn_4);
pan_num.add(btn_5);
pan_num.add(btn_6);
pan_num.add(btn_multi);
pan_num.add(btn_mod);
pan_num.add(btn_1);
pan_num.add(btn_2);
pan_num.add(btn_3);
pan_num.add(btn_sub);
pan_num.add(btn_x);
pan_num.add(btn_0);
pan_num.add(btn_flag);
pan_num.add(btn_point);
pan_num.add(btn_add);
pan_num.add(btn_res);
btn_1.addActionListener(this);
btn_2.addActionListener(this);
btn_3.addActionListener(this);
btn_4.addActionListener(this);
btn_5.addActionListener(this);
btn_6.addActionListener(this);
btn_7.addActionListener(this);
btn_8.addActionListener(this);
btn_9.addActionListener(this);
btn_0.addActionListener(this);
btn_sub.addActionListener(this);
btn_multi.addActionListener(this);
btn_div.addActionListener(this);
btn_add.addActionListener(this);
btn_sqrt.addActionListener(this);
btn_x.addActionListener(this);
btn_res.addActionListener(this);
btn_point.addActionListener(this);
btn_flag.addActionListener(this);
//btn_mod.addActionListener(this);
}
@Override
publicvoidactionPerformed(ActionEvente){
Strings=e.getActionCommand();
BigDecimali=newBigDecimal(1);
Stringtemp=jtf_res.getText().trim();
BigDecimaltemp1=newBigDecimal(temp);
if(e.getSource()==btn_flag){
BigDecimaltemp3=newBigDecimal(jtf_res.getText());
BigDecimaltemp4=newBigDecimal(-1);
BigDecimaltemp5=temp3.multiply(temp4);
jtf_res.setText(""+temp5);
}elseif(s.equals("1/x")){
jtf_res.setText(""+i.divide(temp1,newMathContext(30)));
}elseif(s.equals("sqrt")){
jtf_res.setText(""+temp1.multiply(temp1));
}elseif(s.equals("+")){
str.setLength(0);
if(currentOp==0){
preOp=currentOp=1;
op2=newBigDecimal("0");
jtf_res.setText(""+op1);
}else{
currentOp=preOp;
preOp=1;
switch(currentOp){
case1:
op1=op1.add(op2);
jtf_res.setText(""+op1);
break;
case2:
op1=op1.subtract(op2);
jtf_res.setText(""+op1);
break;
case3:
op1=op1.multiply(op2);
jtf_res.setText(""+op1);
break;
case4:
op1=op1.divide(op2,newMathContext(30));
jtf_res.setText(""+op1);
break;
}
}
}elseif(s.equals("-")){
str.setLength(0);
if(currentOp==0){
preOp=currentOp=2;
jtf_res.setText(""+op1);
}else{
currentOp=preOp;
preOp=2;
switch(currentOp){
case1:
op1=op1.add(op2);
jtf_res.setText(""+op1);
break;
case2:
op1=op1.subtract(op2);
jtf_res.setText(""+op1);
break;
case3:
op1=op1.multiply(op2);
jtf_res.setText(""+op1);
break;
case4:
op1=op1.divide(op2,newMathContext(30));
jtf_res.setText(""+op1);
break;
}
}
}elseif(s.equals("*")){
str.setLength(0);
if(currentOp==0){
preOp=currentOp=3;
jtf_res.setText(""+op1);
}else{
currentOp=preOp;
preOp=3;
switch(currentOp){
case1:
op1=op1.add(op2);
jtf_res.setText(""+op1);
break;
case2:
op1=op1.subtract(op2);
jtf_res.setText(""+op1);
break;
case3:
op1=op1.multiply(op2);
jtf_res.setText(""+op1);
break;
case4:
op1=op1.divide(op2,newMathContext(30));
jtf_res.setText(""+op1);
break;
}
}
}elseif(s.equals("/")){
str.setLength(0);
if(currentOp==0){
preOp=currentOp=4;
jtf_res.setText(""+op1);
}else{
currentOp=preOp;
preOp=4;
switch(currentOp){
case1:
op1=op1.add(op2);
jtf_res.setText(""+op1);
break;
case2:
op1=op1.subtract(op2);
jtf_res.setText(""+op1);
break;
case3:
op1=op1.multiply(op2);
jtf_res.setText(""+op1);
break;
case4:
op1=op1.divide(op2,newMathContext(30));
jtf_res.setText(""+op1);
break;
}
}
}elseif(s.equals("=")){
if(currentOp==0){
str.setLength(0);
jtf_res.setText(""+op2);
}else{
str.setLength(0);
currentOp=preOp;
switch(currentOp){
case1:
op1=op1.add(op2);
jtf_res.setText(""+op1);
break;
case2:
op1=op1.subtract(op2);
jtf_res.setText(""+op1);
break;
case3:
op1=op1.multiply(op2);
jtf_res.setText(""+op1);
break;
case4:
op1=op1.divide(op2,newMathContext(30));
jtf_res.setText(""+op1);
break;
}
currentOp=0;
op2=newBigDecimal("0");
}
}elseif(s.equals(".")){
isBigDecimal=true;
if(jtf_res.getText().trim().indexOf('.')!=-1)
;
else{
if(jtf_res.getText().trim().equals("0")){
str.setLength(0);
jtf_res.setText((str.append("0"+s)).toString());
}elseif(jtf_res.getText().trim().equals("")){
}else{
jtf_res.setText((str.append(s)).toString());
}
}
}elseif(s.equals("0")){
if(jtf_res.getText().trim().equals("0.")){
}else{
jtf_res.setText(str.append(s).toString());
op2=newBigDecimal(jtf_res.getText().trim());
}
}else{
jtf_res.setText(str.append(s).toString());
op2=newBigDecimal(jtf_res.getText().trim());
if(currentOp==0)
op1=op2;
}
}
}
㈦ minecraft里怎么制造最简单的计算器
首先,minecraft原版里面只能用红石电路产生0和1两种信号,然后计算器也是计算机的一回种。。。利用答0和1两种信号来制造计算器就相当于什么?就是相当于你要使用最简单的与或非门来制造计算机!!!所以说是非常复杂的,没有相关的计算机原理知识是无法完成的。。。
以上。。。